.ui-header
	nav
		h1.ui-logo
			a(href="/", target="_self") Logo
		.ui-sign
			if user
				span(href="#", data-toggle="modal", data-target="#signoutModal") 欢迎您,#{user.name}
				span &nbsp;&nbsp;|&nbsp;&nbsp;
				a(href="#", data-toggle="modal", data-target="#signoutModal") 退出
			else
				a(href="#", data-toggle="modal", data-target="#signupModal") 注册
				span(class="ui-sign-line") |
				a(href="#", data-toggle="modal", data-target="#signinModal") 登录
		ul.ui-nav
			li(class="current")
				a(href="/") 首页
			li
				a(href="/") 留言板
#signupModal.modal.fade
	.modal-dialog
		.modal-content
			form(method="POST", action="/user/signup", id="signup")
				.modal-header 注册
				.modal-body
					.form-group
						label(for="signupName") 用户名
						input#signupName.form-control(name="user[name]", type="text")
					.form-group
						label(for="signupPassword") 密码
						input#signupPassword.form-control(name="user[password]", type="text")
				.modal-footer
					button.btn.btn-default(type="button", data-dismiss="modal") 关闭
					button.btn.btn-success(type="submit") 提交
#signinModal.modal.fade
	.modal-dialog
		.modal-content
			form(method="POST", action="/user/signin", id="signin")
				.modal-header 登陆
				.modal-body
					.form-group
						label(for="signinName") 用户名
						input#signipName.form-control(name="user[name]", type="text")
					.form-group
						label(for="signinPassword") 密码
						input#signinPassword.form-control(name="user[password]", type="text")
				.modal-footer
					button.btn.btn-default(type="button", data-dismiss="modal") 关闭
					button.btn.btn-success(type="submit") 提交
#signoutModal.modal.fade
	.modal-dialog
		.modal-content
			form(method="GET", action="/user/signout", id="signout")
				.modal-header 退出登录
				.modal-body
					p 您确定退出吗?
				.modal-footer
					button.btn.btn-default(type="button", data-dismiss="modal") 关闭
					button.btn.btn-success(type="submit") 确定